﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Masters/SubMaster.Master" AutoEventWireup="true" CodeBehind="WebFormWorkersAttachments.aspx.cs" Inherits="CustomersSuppliersWebApplication.WebFormWorkersAttachments" %>

<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="MainContentPlaceHolder" runat="server">
    <telerik:radajaxmanagerproxy id="RadAjaxManagerProxy1" runat="server">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="RadTextBoxSearch">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="RadGridResults" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:radajaxmanagerproxy>

    <telerik:raddockzone id="RadDockZoneMiddle" runat="server" skinid="RadDockZoneContent" cssclass="MinimumPageHeight">
        <telerik:RadDock ID="RadDockSearch" runat="server" Title="بحث" AllowedZones="RadDockZoneMiddle" SkinID="RadDockSearch" CssClass="MarginTop">
            <ContentTemplate>
                <div class="DivSearch FloatRight MarginTop">
                    <asp:Label ID="LabelSearch" runat="server" Text="بحث عام"></asp:Label>
                    <telerik:RadTextBox ID="RadTextBoxSearch" runat="server" SkinID="RadTextBoxSearch" OnTextChanged="RadTextBoxSearch_TextChanged"></telerik:RadTextBox>
                </div>
                <div class="Clear"></div>
            </ContentTemplate>
        </telerik:RadDock>

        <telerik:RadDock ID="RadDockResults" runat="server" Title="النتائج" AllowedZones="RadDockZoneMiddle" SkinID="RadDockResults" CssClass="MarginTop">
            <ContentTemplate>
                <div class="MarginTop">
                    <telerik:RadGrid ID="RadGridResults" runat="server" SkinID="RadGridPrimary" CellSpacing="0" GridLines="None" AutoGenerateColumns="False" ShowGroupPanel="True"
                        OnNeedDataSource="RadGridResults_NeedDataSource" OnItemCommand="RadGridResults_ItemCommand" OnInsertCommand="RadGridResults_InsertCommand" OnItemCreated="RadGridResults_ItemCreated"
                        OnItemDataBound="RadGridResults_ItemDataBound" OnUpdateCommand="RadGridResults_UpdateCommand" OnDeleteCommand="RadGridResults_DeleteCommand">
                        <ClientSettings>
                            <Selecting CellSelectionMode="None" />
                        </ClientSettings>
                        <MasterTableView DataKeyNames="WorkerAttachment_ID" Name="WorkersAttachments">
                            <Columns>
                                <telerik:GridBoundColumn DataField="WorkerAttachment_RowNumber" DataType="System.Int32" UniqueName="WorkerAttachment_RowNumber" HeaderText="الرقم" Display="false" ReadOnly="true">
                                </telerik:GridBoundColumn>
                                <telerik:GridBoundColumn DataField="WorkerAttachment_ID" DataType="System.Guid" UniqueName="WorkerAttachment_ID" HeaderText="الكود" Display="False" ReadOnly="true">
                                </telerik:GridBoundColumn>
                                <telerik:GridBoundColumn DataField="File_DisplayName" DataType="System.String" UniqueName="File_DisplayName" HeaderText="الاسم" Display="true" EditFormColumnIndex="0">
                                </telerik:GridBoundColumn>
                                <telerik:GridBoundColumn DataField="File_Notes" DataType="System.String" UniqueName="File_Notes" HeaderText="الملاحظات" Display="true" EditFormColumnIndex="0">
                                </telerik:GridBoundColumn>
                                <telerik:GridTemplateColumn UniqueName="Attachment_ID" HeaderText="المرفق" EditFormColumnIndex="1">
                                    <ItemTemplate>
                                        <telerik:RadButton ID="RadButtonAttachment" CommandName="ShowAttachment" CommandArgument='<%# Eval("WorkerAttachment_ID") %>' runat="server" SkinID="RadButtonImage">
                                        </telerik:RadButton>
                                    </ItemTemplate>
                                    <EditItemTemplate>
                                        <telerik:RadAsyncUpload ID="RadAsyncUploadAttachment" runat="server">
                                        </telerik:RadAsyncUpload>
                                        <telerik:RadProgressArea ID="RadProgressAreaDefaulet" runat="server">
                                        </telerik:RadProgressArea>
                                    </EditItemTemplate>
                                </telerik:GridTemplateColumn>
                                <telerik:GridEditCommandColumn ButtonType="ImageButton" CancelText="الغاء" EditText="تحرير" UniqueName="EditColumn" UpdateText="حفظ">
                                </telerik:GridEditCommandColumn>
                                <telerik:GridButtonColumn ButtonType="ImageButton" CommandName="Delete" ConfirmDialogHeight="40px" ConfirmDialogType="RadWindow" ConfirmText="هل انت متاكد من عملية الحذف ؟" ConfirmTitle="حذف" Text="حذف" UniqueName="DeleteColumn">
                                </telerik:GridButtonColumn>
                                <telerik:GridRowIndicatorColumn Resizable="True" Visible="true">
                                </telerik:GridRowIndicatorColumn>
                            </Columns>
                            <EditFormSettings>
                                <EditColumn FilterControlAltText="Filter EditCommandColumn column">
                                </EditColumn>
                            </EditFormSettings>
                        </MasterTableView>
                        <FilterMenu EnableImageSprites="False">
                        </FilterMenu>
                    </telerik:RadGrid>
                </div>
            </ContentTemplate>
        </telerik:RadDock>
    </telerik:raddockzone>
</asp:Content>
